package com.itheima.pojo;


import java.io.Serializable;
import java.math.BigDecimal;
import java.util.List;

/**
 * 体检套餐
 */
public class Setmeal implements Serializable {
    private Integer id;
    private String name;
    private String code;
    private String helpCode;
    private Integer sex;//套餐适用性别：0不限 1男 2女
    private String age;//套餐适用年龄
    private BigDecimal price;//套餐价格
    private String remark;
    private String attention;
    private String img;//套餐对应图片存储路径
    private List<CheckGroup> checkGroups;//体检套餐对应的检查组，多对多关系
    private List<Integer> checkGroupIds;
    private Integer status;


    public Integer getStatus() {
        return status;
    }

    public void setStatus(Integer status) {
        this.status = status;
    }

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getCode() {
        return code;
    }

    public void setCode(String code) {
        this.code = code;
    }

    public String getHelpCode() {
        return helpCode;
    }

    public void setHelpCode(String helpCode) {
        this.helpCode = helpCode;
    }

    public Integer getSex() {
        return sex;
    }

    public void setSex(Integer sex) {
        this.sex = sex;
    }

    public String getAge() {
        return age;
    }

    public void setAge(String age) {
        this.age = age;
    }

    public BigDecimal getPrice() {
        return price;
    }

    public void setPrice(BigDecimal price) {
        this.price = price;
    }

    public String getRemark() {
        return remark;
    }

    public void setRemark(String remark) {
        this.remark = remark;
    }

    public String getAttention() {
        return attention;
    }

    public void setAttention(String attention) {
        this.attention = attention;
    }

    public String getImg() {
        return img;
    }

    public void setImg(String img) {
        this.img = img;
    }

    public List<CheckGroup> getCheckGroups() {
        return checkGroups;
    }

    public void setCheckGroups(List<CheckGroup> checkGroups) {
        this.checkGroups = checkGroups;
    }

    public List<Integer> getCheckGroupIds() {
        return checkGroupIds;
    }

    public void setCheckGroupIds(List<Integer> checkGroupIds) {
        this.checkGroupIds = checkGroupIds;
    }

    @Override
    public String toString() {
        return "Setmeal{" +
                "id=" + id +
                ", name='" + name + '\'' +
                ", code='" + code + '\'' +
                ", helpCode='" + helpCode + '\'' +
                ", sex=" + sex +
                ", age='" + age + '\'' +
                ", price=" + price +
                ", remark='" + remark + '\'' +
                ", attention='" + attention + '\'' +
                ", img='" + img + '\'' +
                ", checkGroups=" + checkGroups +
                ", checkGroupIds=" + checkGroupIds +
                ", status=" + status +
                '}';
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;

        Setmeal setmeal = (Setmeal) o;

        if (id != null ? !id.equals(setmeal.id) : setmeal.id != null) return false;
        if (name != null ? !name.equals(setmeal.name) : setmeal.name != null) return false;
        if (code != null ? !code.equals(setmeal.code) : setmeal.code != null) return false;
        if (helpCode != null ? !helpCode.equals(setmeal.helpCode) : setmeal.helpCode != null) return false;
        if (sex != null ? !sex.equals(setmeal.sex) : setmeal.sex != null) return false;
        if (age != null ? !age.equals(setmeal.age) : setmeal.age != null) return false;
        if (price != null ? !(price.compareTo(setmeal.price) ==0) : setmeal.price != null) return false;
        if (remark != null ? !remark.equals(setmeal.remark) : setmeal.remark != null) return false;
        if (attention != null ? !attention.equals(setmeal.attention) : setmeal.attention != null) return false;
        if (img != null ? !img.equals(setmeal.img) : setmeal.img != null) return false;
        if (checkGroups != null ? !checkGroups.equals(setmeal.checkGroups) : setmeal.checkGroups != null) return false;
        if (checkGroupIds != null ? !checkGroupIds.equals(setmeal.checkGroupIds) : setmeal.checkGroupIds != null)
            return false;
        return status != null ? status.equals(setmeal.status) : setmeal.status == null;
    }

    @Override
    public int hashCode() {
        int result = id != null ? id.hashCode() : 0;
        result = 31 * result + (name != null ? name.hashCode() : 0);
        result = 31 * result + (code != null ? code.hashCode() : 0);
        result = 31 * result + (helpCode != null ? helpCode.hashCode() : 0);
        result = 31 * result + (sex != null ? sex.hashCode() : 0);
        result = 31 * result + (age != null ? age.hashCode() : 0);
        result = 31 * result + (price != null ? price.hashCode() : 0);
        result = 31 * result + (remark != null ? remark.hashCode() : 0);
        result = 31 * result + (attention != null ? attention.hashCode() : 0);
        result = 31 * result + (img != null ? img.hashCode() : 0);
        result = 31 * result + (checkGroups != null ? checkGroups.hashCode() : 0);
        result = 31 * result + (checkGroupIds != null ? checkGroupIds.hashCode() : 0);
        result = 31 * result + (status != null ? status.hashCode() : 0);
        return result;
    }
}
